<!-- 本月目标 -->
<template>
  <el-card :header="title" body-style="height:276px">
    <template v-slot:header>
      <span class="titleCard">用户统计</span>
      <more-icon @remove="onRemove" @edit="onEdit" />
    </template>
    <div>
      <!-- 四宫格 -->
      <div class="fourPalaceGrid">
        <div class="singlePalaceGrid">
          <div>
            <img class="icon" src="../../../../assets/Group 3126.png" alt="" />
          </div>
          <div class="accumulateNum">
            <div class="Num">36</div>
            <div>用户数量(个)</div>
          </div>
        </div>
        <div class="singlePalaceGrid">
          <div>
            <img class="icon" src="../../../../assets/Group 3128.png" alt="" />
          </div>
          <div class="accumulateNum">
            <div class="Num">36</div>
            <div>订单数量(个)</div>
          </div>
        </div>
        <div class="singlePalaceGrid">
          <div>
            <img class="icon" src="../../../../assets/Group 2984.png" alt="" />
          </div>
          <div class="accumulateNum">
            <div class="Num">36</div>
            <div>累计充值(元)</div>
          </div>
        </div>
        <div class="singlePalaceGrid">
          <div>
            <img class="icon" src="../../../../assets/Group 3127.png" alt="" />
          </div>
          <div class="accumulateNum">
            <div class="Num">36</div>
            <div>累计消费(元)</div>
          </div>
        </div>
      </div>
      <div class="fourPalaceGrid">
        <div class="singlePalaceGrid">
          <div>
            <img class="icon" src="../../../../assets/Group 3126.png" alt="" />
          </div>
          <div class="accumulateNum">
            <div class="Num">36</div>
            <div>用户数量(个)</div>
          </div>
        </div>
        <div class="singlePalaceGrid">
          <div>
            <img class="icon" src="../../../../assets/Group 3128.png" alt="" />
          </div>
          <div class="accumulateNum">
            <div class="Num">36</div>
            <div>订单数量(个)</div>
          </div>
        </div>
        <div class="singlePalaceGrid">
          <div>
            <img class="icon" src="../../../../assets/Group 2984.png" alt="" />
          </div>
          <div class="accumulateNum">
            <div class="Num">36</div>
            <div>累计充值(元)</div>
          </div>
        </div>
        <div class="singlePalaceGrid">
          <div>
            <img class="icon" src="../../../../assets/Group 3127.png" alt="" />
          </div>
          <div class="accumulateNum">
            <div class="Num">36</div>
            <div>累计消费(元)</div>
          </div>
        </div>
      </div>
    </div>
  </el-card>
</template>

<script setup>
  defineProps({
    title: String
  });

  const emit = defineEmits(['command']);

  const onCommand = (command) => {
    console.log(command);
    emit('command', command);
  };
</script>

<style lang="less" scoped>
  .titleCard {
    &::before {
      content: url('../../../../static/svg/userStatistics.svg');
      display: inline-block;
      vertical-align: middle;
      margin-right: 2px;
      padding-left: 9px;
    }
  }
  .fourPalaceGrid {
    margin: 43px 0;
    display: flex;
    flex-wrap: wrap;
    .singlePalaceGrid {
      width: 25%;
      height: 93px;
      display: flex;
      flex-direction: column;
      align-items: center;
      box-sizing: border-box;
      padding-left: 28px;

      .accumulateNum {
        height: 62px;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: space-evenly;
        .Num {
          color: #1e6ceb;
          font-size: 20px;
        }
      }
    }
    .icon {
      width: 32px;
      height: 32px;
    }
  }

  :deep(.el-card__body) {
    padding: 0;
  }
  .accumulatedSitesBg {
    background-image: url('/src/assets/images/Rectangle 2056.png');
    background-repeat: no-repeat;
    background-size: contain;
    height: 128px;
    width: 400px;

    .padding30 {
      padding: 17px 0 0 20px;
      .sitesNum {
        color: #fff;
        font-size: 30px;
        font-weight: 400;
      }
      .accumulatedSites {
        color: #fff;
      }
    }
  }
  .workplace-goal {
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    position: relative;

    .workplace-goal-body {
      position: absolute;
      top: 50%;
      left: 50%;
      width: 180px;
      margin: -48px 0 0 -90px;
      text-align: center;
    }
  }
</style>
